﻿<%@ Page Language="C#" AutoEventWireup="true" CodeFile="teacher.aspx.cs" Inherits="Admin1_Default" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
    <title></title>
    <link href="../css/Common.css" rel="stylesheet" type="text/css" />
    <link href="../css/admin.css" rel="stylesheet" type="text/css" />
    <link href="../layui/css/layui.css" rel="stylesheet" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0, minimum-scale=0.5, maximum-scale=2.0, user-scalable=yes" />
    <style type="text/css">
        #top {
            height: 90px;
            width: 100%;
            background-color: #ebf3ff;
            line-height: 25px;
        }

        .top-left {
            width: 15px;
            float: left;
        }

            .top-left img {
            }

        .top-center {
            width: 300px;
            float: left;
        }

        .top-right {
            padding-left: 30%;
            padding-bottom: 1px;
        }

        #bottom {
            margin: 0px auto;
            height: 79px;
        }

        .footer {
            width: 100%;
            margin: 0px auto;
            height: 50px;
            margin-top: 10px;
            text-align: center;
        }

        .middle {
            width: 100%;
            height: 500px;
        }

        .middle_left {
            width: 10%;
            height: 100%;
            float: left;
            background-color: rgb(133,177,238)
        }

        .middle_right {
            width: 90%;
            height: 700px;
            float: left;
            background: white;
        }

        #iframe {
            height: 100%;
            width: 100%;
            background: white;
        }

        .middle_head {
            height: 30px;
            width: 1000px;
            margin: 0px auto;
        }

        #select {
            background-color: rgb(133,177,238);
            height: 40px;
        }

        #select_left {
            width: 300px;
            height: 22px;
            float: left;
            margin-top: 15px;
        }

        #select_right {
            width: 80px;
            height: 20px;
            float: right;
            margin-top: 21px;
            margin-right: 8px;
        }

        #localtime {
            font: 600px;
            color: white;
        }
    </style>
</head>
<body id="body">
    <form id="form1" runat="server">
        <div id="top">
            <div class="top-left">
                <img src="../image/logo.png" style="background-color: none" alt="" />
            </div>
            <div class="top-right">
                <img src="../image/title.png" />
            </div>

        </div>

        <div id="select">
            <div style="padding-left: 83%; padding-top: 5px">
                <asp:Label ID="Label3" runat="server" Text="Label" BorderColor="White" Font-Bold="True" Font-Size="20px" ForeColor="White"></asp:Label>|
          <%--  <span id="localtime"></span>--%>

                <a href="../index.aspx" style="font-size: 20px; color: white; font-weight: bold">退出</a>
            </div>

        </div>
        <div class="middle">
            <div class="middle_left">
                <ul id="nav">
                    <li><a href="#Menu=ChildMenu1" onclick="DoMenu('ChildMenu1')">关键用户管理</a>
                        <ul id="ChildMenu1" class="collapsed">
                            <li><a href="../Admin/ManageStudent.aspx" target="mainFrame">关键用户信息</a></li>
                            <li><a href="ManageStudentNew.aspx" target="mainFrame">(NEW)关键用户信息</a></li>
                            <%--<li><a href="UserBindingPaper.aspx" target="mainFrame">用户试卷绑定</a></li>--%>
                            <li><a href="ManageScore.aspx" target="mainFrame">关键用户成绩</a></li>
                            <li><a href="../Admin/AddStudent.aspx" target="mainFrame">增加关键用户</a></li>
                        </ul>
                    </li>
                    <li><a href="#Menu=ChildMenu2" onclick="DoMenu('ChildMenu2')">考试科目信息</a>
                        <ul id="ChildMenu2" class="collapsed">
                            <li><a href="AddCourse.aspx" target="mainFrame">考试科目添加</a></li>
                            <li><a href="ManageCourse.aspx" target="mainFrame">考试科目管理</a></li>
                        </ul>
                    </li>
                    <li><a href="#Menu=ChildMenu4" onclick="DoMenu('ChildMenu4')">试题</a>
                        <ul id="ChildMenu4" class="collapsed">
                            <li><a href="AddDanXuan.aspx" target="mainFrame">单选题录入</a></li>
                            <li><a href="ManageDanXuan.aspx" target="mainFrame">单选题维护</a></li>
                            <li><a href="AddDuoXuan.aspx" target="mainFrame">多选题录入</a></li>
                            <li><a href="ManageDuoXuan.aspx" target="mainFrame">多选题维护</a></li>
                            <li><a href="AddPanDuan.aspx" target="mainFrame">判断题录入</a></li>
                            <li><a href="ManagePanDuan.aspx" target="mainFrame">判断题维护</a></li>
                            <li><a href="AddAskAnswer.aspx" target="mainFrame">问答题录入</a></li>
                            <li><a href="ManageAskAnswer.aspx" target="mainFrame">问答题维护</a></li>
                        </ul>
                    </li>
                    <li><a href="#Menu=ChildMenu3" onclick="DoMenu('ChildMenu3')">试卷</a>
                        <ul id="ChildMenu3" class="collapsed">
                            <li><a href=" PaperList.aspx" target="mainFrame">试卷库</a></li>
                            <li><a href="AddTaoTi.aspx" target="mainFrame">试卷制定</a></li>
                            <li><a href="ManageTaoTi.aspx" target="mainFrame">试卷维护</a></li>
                        </ul>
                    </li>
                    <li><a href="#Menu=ChildMenu6" onclick="DoMenu('ChildMenu6')">试卷批改</a>
                        <ul id="ChildMenu6" class="collapsed">
                            <li><a href="CORRECTASKANSWER.aspx" target="mainFrame">简答题批改</a></li>
                        </ul>
                    </li>


                    <li><a href="#Menu=ChildMenu5" onclick="DoMenu('ChildMenu5')">修改密码</a>
                        <ul id="ChildMenu5" class="collapsed">
                            <li><a href="ChangePwd.aspx" target="mainFrame">修改密码</a></li>
                              <li><a href="teacherLayui.aspx">新页面</a></li>
                        </ul>
                    </li>
                </ul>
            </div>
            <div class="middle_right">
                <iframe id="iframe" name="mainFrame" frameborder="0"
                    scrolling="auto" src=""
                    allowtransparency="true"></iframe>
            </div>
        </div>
        <div class="clear"></div>
        <div id="bottom">
            <div class="footer">
                <p style="font-size: 12px; color: #575757">Copyright @2018 健新智能科技有限公司</p>
            </div>
        </div>
    </form>
    <script type="text/javascript">
        var LastLeftID = "";
        function menuFix() {
            var obj = document.getElementById("nav").getElementsByTagName("li");

            for (var i = 0; i < obj.length; i++) {
                obj[i].onmouseover = function () {
                    this.className += (this.className.length > 0 ? " " : "") + "sfhover";
                }
                obj[i].onMouseDown = function () {
                    this.className += (this.className.length > 0 ? " " : "") + "sfhover";
                }
                obj[i].onMouseUp = function () {
                    this.className += (this.className.length > 0 ? " " : "") + "sfhover";
                }
                obj[i].onmouseout = function () {
                    this.className = this.className.replace(new RegExp("( ?|^)sfhover\\b"), "");
                }
            }
        }
        function DoMenu(emid) {
            var obj = document.getElementById(emid);
            obj.className = (obj.className.toLowerCase() == "expanded" ? "collapsed" : "expanded");
            if ((LastLeftID != "") && (emid != LastLeftID)) //关闭上一个Menu
            {
                document.getElementById(LastLeftID).className = "collapsed";
            }
            LastLeftID = emid;
        }


        window.onload = function () {
            let main = document.getElementById("body");
            main.style.height = window.innerHeight;
            main.style.width = window.innerWidth * 0.8;


        }


        function showLocale(objD) {
            var str, colorhead, colorfoot;
            var yy = objD.getYear();
            if (yy < 1900) yy = yy + 1900;
            var MM = objD.getMonth() + 1;
            if (MM < 10) MM = '0' + MM;
            var dd = objD.getDate();
            if (dd < 10) dd = '0' + dd;
            var hh = objD.getHours();
            if (hh < 10) hh = '0' + hh;
            var mm = objD.getMinutes();
            if (mm < 10) mm = '0' + mm;
            var ss = objD.getSeconds();
            if (ss < 10) ss = '0' + ss;
            var ww = objD.getDay();
            if (ww == 0) colorhead = "<font color=\"#FF0000\">";
            if (ww > 0 && ww < 6) colorhead = "<font color=\"#aeaeae\">";
            if (ww == 6) colorhead = "<font color=\"#008000\">";
            if (ww == 0) ww = "星期日";
            if (ww == 1) ww = "星期一";
            if (ww == 2) ww = "星期二";
            if (ww == 3) ww = "星期三";
            if (ww == 4) ww = "星期四";
            if (ww == 5) ww = "星期五";
            if (ww == 6) ww = "星期六";
            colorfoot = "</font>"
            str = colorhead + yy + "-" + MM + "-" + dd + " " + hh + ":" + mm + ":" + ss + "  " + ww + colorfoot;
            return (str);
        }
        function tick() {
            var today;
            today = new Date();
            let localtime = document.getElementById("localtime");
            localtime.innerHTML = showLocale(today);

            window.setTimeout("tick()", 1000);
        }
        tick();

        function GetMenuID() {
            var MenuID = "";
            var _paramStr = new String(window.location.href);
            var _sharpPos = _paramStr.indexOf("#");

            if (_sharpPos >= 0 && _sharpPos < _paramStr.length - 1) {
                _paramStr = _paramStr.substring(_sharpPos + 1, _paramStr.length);
            }
            else {
                _paramStr = "";
            }

            if (_paramStr.length > 0) {
                var _paramArr = _paramStr.split("&");
                if (_paramArr.length > 0) {
                    var _paramKeyVal = _paramArr[0].split("=");
                    if (_paramKeyVal.length > 0) {
                        MenuID = _paramKeyVal[1];
                    }
                }
                /*
                if (_paramArr.length>0)
                {
                var _arr = new Array(_paramArr.length);
                }
      
                //取所有#后面的，菜单只需用到Menu
                //for (var i = 0; i < _paramArr.length; i++)
                {
                var _paramKeyVal = _paramArr[i].split('=');
       
                if (_paramKeyVal.length>0)
                {
                _arr[_paramKeyVal[0]] = _paramKeyVal[1];
                }  
                }
                */
            }

            if (MenuID != "") {
                DoMenu(MenuID)
            }
        }
        GetMenuID(); //*这两个function的顺序要注意一下，不然在Firefox里GetMenuID()不起效果
        menuFix();
        --></script>
</body>
</html>
